home *** CD-ROM | disk | FTP | other *** search
/ Aminet 5 / Aminet 5 - March 1995.iso / Aminet / dev / basic / RIBlitzLibs.lha / riblitzlibs / docs / RITrackDiskLib.doc < prev    next >
Encoding:
Text File  |  1995-01-28  |  3.3 KB  |  99 lines

  1. -----------------------------------------------------------------------------
  2. ====                  RI TrackDisk Library V1.2 (C)1994              ====
  3. -----------------------------------------------------------------------------
  4.  
  5.                           Written By Steven Matty
  6.                         ©1994 Leading Edge Software
  7.  
  8.  
  9. Command List:
  10.  
  11.     success=OpenDisk(unit#)
  12.     MotorOn unit#
  13.     MotorOff unit#
  14.     CloseDisk unit#
  15.     success=ReadSector(unit#,sector#,buffer[,numsectors])
  16.     success=WriteSector(unit#,sector#,buffer[,numsectors])
  17.     success=FormatTrack(unit#,track#,buffer[,numtracks])
  18.     success=WriteBoot(unit#[,bootdata])
  19.  
  20.  
  21. Statement/Function : OpenDisk
  22. ---------------------------------------------------------------------------
  23. Modes  : Amiga
  24. Syntax : success=OpenDisk(unit#)
  25.  
  26. This attempts to open unit 'unit#' of the trackdisk.device, for use with
  27. the other Statement/Functions in this library. A return value of 0 indicates failure,
  28. -1 indicates success.
  29.  
  30.  
  31. Statement : MotorOn
  32. ---------------------------------------------------------------------------
  33. Modes  : Amiga
  34. Syntax : MotorOn unit#
  35.  
  36. This attempts to switch the drive motor on of the previously opened
  37. trackdisk unit (called with OpenDisk). You must call this Statement/Function
  38. before attempting to ReadSector/WriteSector/FormatTrack/WriteBoot
  39.  
  40.  
  41. Statement : MotorOff
  42. ---------------------------------------------------------------------------
  43. Modes  : Amiga
  44. Syntax : MotorOff unit#
  45.  
  46. This turns the drive motor of 'unit#' off.
  47.  
  48.  
  49. Statement/Function : ReadSector
  50. ---------------------------------------------------------------------------
  51. Modes  : Amiga
  52. Syntax : [success=]ReadSector(unit#,sector#,buffer[,numsectors])
  53.  
  54. This attempts to read 'numsectors' sectors from a trackdisk device which
  55. has been opened with OpenDisk and has its Motor On. If numsectors is
  56. omitted then 1 sector is read. The data is read into the memory location
  57. pointed to by 'buffer'.
  58.  
  59. WARNING! Please MAKE SURE the MOTOR is _ON_ otherwise, all hell will break
  60. loose!!!
  61.  
  62.  
  63. Statement/Function : WriteSector
  64. ---------------------------------------------------------------------------
  65. Modes  : Amiga
  66. Syntax : [success=]WriteSector(unit#,sector#,buffer[,numsectors])
  67.  
  68. This is the same as ReadSector except........... it writes!
  69. (and no, I am not being lazy by not typing any decent docs)
  70.  
  71.  
  72. Statement/Function : FormatTrack
  73. ---------------------------------------------------------------------------
  74. Modes  : Amiga
  75. Syntax : [success=]FormatTrack(unit#,track#,buffer[,numtracks])
  76.  
  77. This does a TD_FORMAT on the specified track number. Buffer should point
  78. to the area of memory which the track should be formatted with. I don't
  79. know why this Statement/Function exists - but hey, it might come in useful.
  80.  
  81.  
  82. Statement/Function : WriteBoot
  83. ---------------------------------------------------------------------------
  84. Modes  : Amiga
  85. Syntax : [success=]WriteBoot(unit#[,buffer])
  86.  
  87. This writes 1k of data to the bootblock of the specified disk unit.
  88. The optional buffer parameter should point to an area of memory with which
  89. to write the bootblock.
  90.  
  91.  
  92. Statement : CloseDisk
  93. ---------------------------------------------------------------------------
  94. Modes  : Amiga
  95. Syntax : CloseDisk unit#
  96.  
  97. This closes the trackdisk.device of the specified unit#. The Motor is
  98. automatically switched off if it is already on.
  99.